import request from '@/utils/request'

// 查询平台分享列表
export function listShare(query) {
  return request({
    url: '/share/list',
    method: 'get',
    params: query
  })
}

// 查询平台分享详细
export function getShare(id) {
  return request({
    url: '/share/' + id,
    method: 'get'
  })
}

// 新增平台分享
export function addShare(data) {
  return request({
    url: '/share',
    method: 'post',
    data: data
  })
}

// 修改平台分享
export function updateShare(data) {
  return request({
    url: '/share',
    method: 'put',
    data: data
  })
}

// 删除平台分享
export function delShare(id) {
  return request({
    url: '/share/' + id,
    method: 'delete'
  })
}

export function getAll(query) {
  return request({
    url: '/share/getAll',
    method: 'get',
    params: query
  })
}

